Common issues with pull requests
Hardcoding values
- If you are hardcoding the same value over and over make a constant for it in Constants.ts and use that new constant instead
Non-descript variable names
- Make sure your variables names are descriptive
Passing checks
- Before submitting a PR make sure you run the tests (
yarn test
) to make sure everything is still working correctly after your changes
- Before submitting a PR make sure you run the tests (
Imports
- Before Submitting a PR consult the import style guide to make sure your order of imports adheres to it
Please make sure the changes in your PR actually belong in your PR
- Don't make random or unnecessary changes that don't have anything to do with the issues your working on
- If you’re working on multiple issues you should have a separate branch and pull request for each issue
Run OpenCircuits
- Make sure OpenCircuits still runs after the changes you've made and test out the changes you've made to ensure they are working
Don't re-implement code
- If you are unsure if some functionality already exists in the codebase you should ask rather attempting to re-implement it
Comments
- If you think a peice of code will be hard for another person to understand make sure to write comments
Stick to the code formatting around you
- make sure the style and formatting of the code is the same before and after you've changed it
Tabs
- Don't submit a PR with tabs in it (any tabs should instead be 4 spaces)
Remove extraneous comments
- If your PR has comments that are no longer relevant to the code make sure to remove them
Whitespace
- Make sure there is no extra whitespace in your PR
Make sure you include a space after if
- Do
if (bool)
notif(bool)
- Do
Make sure you have an space after each comment
- Do
// "stuff"
not//"stuff"
- Do
You do not need to merge master unless there is a conflict
- You do not need to press the
Update Branch
button (on Github) unless there is a merge conflict
- You do not need to press the